<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;

class AddUserAdmTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('userAdm', function (Blueprint $table) {
            $table->string('salt')->after('status')->comment('秘钥');
            $table->integer('validity')->after('type')->comment('PC有效时间');
            $table->string('ipadToken')->after('validity')->comment('ipadToken');
            $table->integer('ipadValidity')->after('ipadToken')->comment('IPad有效时间');
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
//        Schema::table('userAdm', function (Blueprint $table) {
//            $table->dropColumn(['validity']);
//        });
    }
}
